﻿<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<CollaborationRoom>" %>
<%@ Import Namespace="ViewRes" %>

    <div>
        <%:LecturerStrings.StudentProposals%>
    </div>
    <div id="divAccordion">
        <%
            foreach (CollaborationPropose propose in Model.CollaborationProposes)
            {%>
            <h3><a href="#"><%:string.Format("{0} - {1}", propose.Student.ToString(), propose.DateTime)%> </a></h3>
            <div>
            <%
                if (propose.Theme != null)
                {%>
                <span class="smallgreentext"><%:LecturerStrings.ProposedTheme%></span>
                <div class="bodytext"><%:propose.Theme%></div>
                
                <%
                }%>
                <%
                if (propose.Description != null)
                {%>
                <span class="smallgreentext"><%:LecturerStrings.ProposedDescription%></span>
                <div class="bodytext"><%:propose.Description%></div>
                <%
                }%>
                <br />
                <a href="<%:Url.RouteUrl("Default",
                                               new
                                                   {
                                                       controller = "CollaborationRooms",
                                                       action = "RefuseStudent",
                                                       studentId = propose.StudentId
                                                   })%>" style="float: right;">
                    <img src="<%:Url.Content("~/Content/Icons/stop_icon.png")%>" class="mediumIcon" title="<%:ViewRes.LecturerStrings.Decline%>" />
                </a>
                <a href="<%:Url.RouteUrl("Default",
                                               new
                                                   {
                                                       controller = "CollaborationRooms",
                                                       action = "Approve",
                                                       roomId = propose.CollaborationRoomId,
                                                       studentId = propose.StudentId
                                                   })%>" style="float: right;">
                    <img src="<%:Url.Content("~/Content/Icons/job-done.png")%>" class="mediumIcon" title="<%:LecturerStrings.Accept%>" />
                </a>

                

            </div>
        <%
            }%>
    </div>
